/*
 * $Id: AbstractTask.java,v 1.3 2009/07/24 18:27:41 oliver Exp $
 *
 * Copyright (C) 2006 General Electric Company. All Rights Reserved.
 *
 * This software is the confidential and proprietary information of the General
 * Electric Company (GE). You shall not disclose this software and shall use it
 * only in accordance with the terms of the license agreement you entered into
 * with GE.
 *
 * GE MAKES NO REPRESENTATIONS OR WARRANTIES ABOUT THE SUITABILITY OF THE
 * SOFTWARE, EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED
 * WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
 * NON-INFRINGEMENT. GE SHALL NOT BE LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
 * AS A RESULT OF USING, MODIFYING, OR DISTRIBUTING THIS SOFTWARE OR ITS
 * DERIVATIVES.
 */

/*
 * WARNING: DO NOT EDIT THIS FILE. This is a generated file that is synchronized
 * by MyEclipse Hibernate tool integration.
 *
 * Created Wed Dec 31 15:32:26 CST 2008 by MyEclipse Hibernate Tool.
 */
package com.ge.healthcare.autosc.common.database.pojo;

import java.io.Serializable;
import java.util.Date;

import com.ge.healthcare.autosc.common.message.converter.AutoSCMessage;

/**
 * A class that represents a row in the ACT_TASK table. You can customize the
 * behavior of this class by editing the class, {@link ActTask()}. WARNING: DO
 * NOT EDIT THIS FILE. This is a generated file that is synchronized by
 * MyEclipse Hibernate tool integration.
 */
public abstract class AbstractTask implements AutoSCMessage, Serializable {
	/**
	 * Eclipse generated
	 */
	private static final long serialVersionUID = -8622632753994970696L;

	/**
	 * The cached hash code value for this instance. Setting to 0 triggers
	 * re-calculation.
	 */
	private int hashValue = 0;

	/** The composite primary key value. */
	private java.lang.Long taskId;

	/** The value of the actRequest association. */
	private Long requestId;
	private Long parentId;
	private Long failedCount;
	private Long stepTypeId;

	/** The value of the cfgCodeDetails association. */
	private Long codeId;

	/** The value of the simple taskType property. */
	private java.lang.String taskType;
	private Character extAutosc;

	/** The value of the simple startTime property. */
	private java.util.Date startTime;

	/** The value of the simple endTime property. */
	private java.util.Date endTime;

	private Long priority;
	private Date expireDate;
	private Date retryUntil;

	public Character getExtAutosc() {
		return extAutosc;
	}

	public void setExtAutosc(Character extAutosc) {
		this.extAutosc = extAutosc;
	}

	/**
	 * Simple constructor of AbstractTask instances.
	 */
	public AbstractTask() {
	}

	/**
	 * Constructor of AbstractTask instances given a simple primary key.
	 * 
	 * @param taskId
	 */
	public AbstractTask(java.lang.Long taskId) {
		this.setTaskId(taskId);
	}

	/**
	 * Return the simple primary key value that identifies this object.
	 * 
	 * @return java.lang.Long
	 */
	public java.lang.Long getTaskId() {
		return taskId;
	}

	/**
	 * Set the simple primary key value that identifies this object.
	 * 
	 * @param taskId
	 */
	public void setTaskId(java.lang.Long taskId) {
		this.hashValue = 0;
		this.taskId = taskId;
	}

	/**
	 * Return the value of the REQUEST_ID column.
	 * 
	 * @return ActRequest
	 */
	public Long getRequestId() {
		return this.requestId;
	}

	/**
	 * Set the value of the REQUEST_ID column.
	 * 
	 * @param actRequest
	 */
	public void setRequestId(Long requestId) {
		this.requestId = requestId;
	}

	/**
	 * Return the value of the TASK_TYPE column.
	 * 
	 * @return java.lang.String
	 */
	public java.lang.String getTaskType() {
		return this.taskType;
	}

	/**
	 * Set the value of the TASK_TYPE column.
	 * 
	 * @param taskType
	 */
	public void setTaskType(java.lang.String taskType) {
		this.taskType = taskType;
	}

	/**
	 * Return the value of the CODE_ID column.
	 * 
	 * @return CfgCodeDetails
	 */
	public Long getCodeId() {
		return this.codeId;
	}

	public void setCodeId(Long codeId) {
		this.codeId = codeId;
	}

	/**
	 * Implementation of the equals comparison on the basis of equality of the
	 * primary key values.
	 * 
	 * @param rhs
	 * @return boolean
	 */
	public boolean equals(Object rhs) {
		if (rhs == null)
			return false;
		if (!(rhs instanceof ActTask))
			return false;
		ActTask that = (ActTask) rhs;
		if (this.getTaskId() == null || that.getTaskId() == null)
			return false;
		return (this.getTaskId().equals(that.getTaskId()));
	}

	/**
	 * Implementation of the hashCode method conforming to the Bloch pattern
	 * with the exception of array properties (these are very unlikely primary
	 * key types).
	 * 
	 * @return int
	 */
	public int hashCode() {
		if (this.hashValue == 0) {
			int result = 17;
			int taskIdValue = this.getTaskId() == null ? 0 : this.getTaskId()
					.hashCode();
			result = result * 37 + taskIdValue;
			this.hashValue = result;
		}
		return this.hashValue;
	}

	public Long getFailedCount() {
		return failedCount;
	}

	public void setFailedCount(Long failedCount) {
		this.failedCount = failedCount;
	}

	public Long getStepTypeId() {
		return stepTypeId;
	}

	public void setStepTypeId(Long stepTypeId) {
		this.stepTypeId = stepTypeId;
	}

	public Long getParentId() {
		return parentId;
	}

	public void setParentId(Long parentId) {
		this.parentId = parentId;
	}

	/**
	 * @return the startTime
	 */
	public java.util.Date getStartTime() {
		return startTime;
	}

	/**
	 * @param startTime
	 *            the startTime to set
	 */
	public void setStartTime(java.util.Date startTime) {
		this.startTime = startTime;
	}

	/**
	 * @return the endTime
	 */
	public java.util.Date getEndTime() {
		return endTime;
	}

	/**
	 * @param endTime
	 *            the endTime to set
	 */
	public void setEndTime(java.util.Date endTime) {
		this.endTime = endTime;
	}

	/**
	 * @return the priority
	 */
	public Long getPriority() {
		return priority;
	}

	/**
	 * @param priority the priority to set
	 */
	public void setPriority(Long priority) {
		this.priority = priority;
	}

	/**
	 * @return the expireDate
	 */
	public Date getExpireDate() {
		return expireDate;
	}

	/**
	 * @param expireDate the expireDate to set
	 */
	public void setExpireDate(Date expireDate) {
		this.expireDate = expireDate;
	}

	/**
	 * @return the retryUntil
	 */
	public Date getRetryUntil() {
		return retryUntil;
	}

	/**
	 * @param retryUntil the retryUntil to set
	 */
	public void setRetryUntil(Date retryUntil) {
		this.retryUntil = retryUntil;
	}
}
